package com.outsider.tools;

import com.outsider.dictlistbea.MainActivity;

import android.os.Handler;
import android.os.Message;

public class LoadingHandler extends Handler {
	public static final int START = 1;
	public static final int END = 0;
	
	private MainActivity activity;
	
	public LoadingHandler(MainActivity activity){
		this.activity = activity;
	}
	
	public void handleMessage(Message msg) {

		switch (msg.what) {
		case LoadingHandler.START: {
			activity.showLoading();
			break;
		}
		case LoadingHandler.END: {
			activity.afterAddMult();
			activity.hideLoading();
		}
		
		}
		super.handleMessage(msg);
	}
}
